\section{Preliminary}

% This study investigates the task of knowledge-based question answering (KBQA).

% Knowledge Graph. A knowledge graph (KG) consists of a number of triples to store the factual knowledge, denoted as K = { (s, r, o) | s ∈ E, r ∈ R, o ∈ E ∪ L }, where E, R and L denote the set of entities, relations and literals, respectively. A triple ⟨ s, r, o ⟩ represents the fact that there is a relation r between the head entity s and the tail entity o.

% Logical Form. A logical form is a formal representation of a natural language question. 以sparql表达式为例， A SPARQL query is a graph pattern matching query, which enables users to query information from databases or any data source that can be mapped to RDF

% Problem Formulation. given a natural language question Q, and a knowledge base K, our goal is to generates the expected sparql query S to answer the question q.


In this section, we introduce the definition of knowledge base. Different knowledge bases model the factual knowledge in different ways. We also introduce the definition of logical form and present the unified problem statement.

Knowledge Graph. A knowledge graph (KG) consists of a number of triples to store the factual knowledge, denoted as K = { (s, r, o) }. A triple ⟨ s, r, o ⟩ represents the fact that there is a relation r between the subject s and the object o.


Freebase Knowledge Graph. In Freebase, K = { (s, r, o) | s ∈ E, r ∈ R, o ∈ E ∪ L } where E, R and L denote the set of entities, relations and literals, respectively. 

% kqapro: KB Definition Typically, a KB (e.g., Wikidata (Vrandeˇci´c and Krötzsch, 2014)) consists of:
% Entity, the most basic item in KB.
% Concept, the abstraction of a set of entities, e.g., basketball player.
% Relation, the link between entities or concepts. Entities are linked to concepts via the relation instance of. Concepts are organized into a tree structure via relation subclass of.
% Attribute, the literal information of an entity. An attribute has a key and a value, which is one of four types 1 : string, number, date, and year. The number value has an extra unit, e.g., 206 centimetre. 
% Relational knowledge, the triple with form (entity, relation, entity), e.g., (LeBron James Jr., father, LeBron James).
% Literal knowledge, the triple with form (entity, attribute key, attribute value), e.g., (LeBron James, height, 206 centimetre).
% Qualifier knowledge, the triple whose head is a relational or literal triple, e.g., ((LeBron James, drafted by, Cleveland Cavaliers), point in time, 2003). A qualifier also has a key and a value.
Wikidata Knowledge Graph. In Wikidata, K = { (s, r, o) | s ∈ E ∪ C, r ∈ R ∪ Attr ∪ Qual, o ∈ E ∪ L ∪ F }, where E, C, R, Attr, Qual, L and F denote the set of entities, concepts, relations, attributes, qualifiers, literals and relational knowledge(脚注 triple with form (entity, relation, entity), e.g., (LeBron James Jr., father, LeBron James).), respectively. 


In Wikidata, E consists of entities and concepts, R consists of relations, attributes and qualifiers, and o consists of E and Literal value.

MetaQA Knowledge Graph. In MetaQA, E consists of entities, R consists of relations, and L consists of E and Literal value.







